<template>
	<view class="cont_bo">
		<view class="s_titles">查看发票（共1张）</view>
		<view class="fp_imgs">
			<image src="https://cdn-static.yekjx.com/food/images/rec_img01.png" style="width: 100%;height: 100%;"
				@click="handelPre"></image>
		</view>
		<!-- <view class="full_btn fixed padding-top-lg text-lg">
		  	<view class="mbtn">
		  		下 载
		  	</view>
		  </view> -->
	</view>
</template>

<script setup lang="ts">
	import { ref } from 'vue';
	import { env } from '@/api/env.js'
	import { onLoad } from '@dcloudio/uni-app';
	const imgurlList = ref(["https://cdn-static.yekjx.com/food/images/rec_img01.png"])
	onLoad(options => {
		console.log(options, "onLoad")
		if (options.imgurl) {
			imgurlList.value.push(
				env.imgBaseUrl + options.imgurl
			)

		}
	})
 
	const handelPre = () => {
		let index = 0;
		uni.previewImage({
			current: imgurlList.value[index],
			urls: imgurlList.value,
			success: () => {
				console.log("111")
			}
		})
	}
</script>

<style lang="scss" scoped>
	.cont_bo {
		width: 100vw;
		height: 100vh;
		background-color: #fff;
		padding-top: 10rpx;

		.s_titles {
			color: #333;
			font-family: "Microsoft YaHei UI";
			font-size: 48rpx;
			font-weight: 400;
			padding: 20rpx 40rpx 10rpx 40rpx;
		}

		.fp_imgs {
			width: 100%;
			height: 490rpx;
			background: #F6F7FB;
			padding: 20rpx;
			margin-top: 10rpx;
		}
	}
</style>